{% extends "djips/common/base.html" %}
{% load djips_extras %}
{% load i18n %}

{% block title %}
{% trans "Synchronize filesystem" %}
{% endblock %}

{% block content %}

{% if synchronized %}
<p class="info_msg">{% blocktrans with new_folders|length as new_folders_length and new_images|length as new_images_length and deleted_folders|length as deleted_folders_length and  deleted_images|length as deleted_images_length %}
 Filesystem and database have been
  synchronized: {{new_folders_length}} folders and
  {{new_images_length}} images added, {{deleted_folders_length}}
  folders and {{deleted_images_length}} images removed.
  {% endblocktrans %}</p>
{% endif %}
{% if root %}
  <p>{% trans "Click on the folder you want to synchronize." %}</p>
  {{root|djips_filesystem:filesystem_options}}
{% else %}
  <form action="{{admin_base_url}}/djips_common/synchronize/-1/">
  <p>{% trans "You never synchronized file system." %}</p>
  <input type="submit" value="Synchronize filesystem" />
</form>
{% endif %}

{% endblock %}
